package com.cqw.order.handlers;

import com.cqw.handers.BaseEnumHandler;
import com.cqw.order.enums.ItemStateEnum;

/**
 * @Author: caoqingwen
 * @CreateTime: 2021-07-12 11:43
 * @Description:
 */
public class ItemStateEnumHandler extends BaseEnumHandler<ItemStateEnum> {

    @Override
    public Integer getCode(ItemStateEnum enumEntity) {
        return enumEntity.code();
    }


    @Override
    public ItemStateEnum getEnumEntity(int code) {
        return ItemStateEnum.parse(code);
    }
}
